//
//  String+Category.swift
//  cxd4iphone
//
//  Created by hexy on 12/28/15.
//  Copyright © 2015 hexy. All rights reserved.
//

import UIKit

extension String {
    
    static func num3Formmter(num: Double) -> String {
        
        let fomter = NSNumberFormatter()
        fomter.positiveFormat = "###,##0.00"
        return fomter.stringFromNumber(NSNumber(double: num))!

        
    }
    
    static func num4Formmter(num: Double) -> String {
        
        let fomter = NSNumberFormatter()
        fomter.positiveFormat = "####,####"
        return fomter.stringFromNumber(NSNumber(double: num))!
    }

}